﻿using System;
using System.Collections.Generic;
using Jayden.Dll.Web.HtmlControls.Descriptions;
using Jayden.Dll.Web.HtmlControls.Generics;
using Jayden.Dll.Web.HtmlControls.Interfaces;

namespace Jayden.Dll.Web.HtmlControls
{
	public class Menu : HtmlElement, WithLabel, WithType
	{
		public Menu() : base(MenuDescription.Instance) { }

		public string Type { get { return this["type"]; } set { this["type"] = value; } }
		public string Label { get { return this["label"]; } set { this["label"] = value; } }
	}
	public class MenuDescription : HtmlElementDescription
	{
		public static readonly MenuDescription Instance = new MenuDescription();
		private MenuDescription() : base("menu") { }
		public override Type ControlType { get { return typeof(Menu); } }
		public override bool OnlyFlowContent { get { return true; } }
		public override bool IsFlowElement { get { return true; } }
		public override IEnumerable<HtmlElementDescription> PermittedElements { get { yield return LiDescription.Instance; } }
		public override string Description { get { return "list of commands."; } }
	}
}
